<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src='https://unpkg.com/@antv/l7'></script>
    <script src="https://lib.baomitu.com/jquery/2.2.4/jquery.js"></script>
    <style>
        * {
            margin: 0;
            padding: 0
        }

        #map {
            width: 100vw;
            height: 100vh;
        }

        html,
        body {
            overflow: hidden;
        }
    </style>
</head>

<body>
    <div id="map">

    </div>
    <script>
        var { Scene, GaodeMap } = L7;
        const scene = new Scene({
            id: 'map',
            map: new GaodeMap({
                /* dark|light|normal */
                style: 'normal', // 样式URL
                center: [114.30, 30.50],
                pitch: 30,
                zoom: 2,
                // token: '3851594382e218c49865a4d6a5170b52',
            }),
            logoVisible: false
        });
        scene.on("loaded", () => {
            $.ajax({
                url: "./data/globe_wind.json"
            }).then(data => {
                const layer = new L7.LineLayer({
                    blend: 'normal'
                })
                    .source(data)
                    .size(1)
                    .shape('arc')
                    .color('#6495ED')
                    .animate({
                        duration: 4,
                        interval: 0.2,
                        trailLength: 0.6
                    })
                scene.addLayer(layer);
            })
        })
    </script>
</body>

</html>